<template>
  <div>
    <a-list
      class="demo-loadmore-list"
      item-layout="horizontal"
      :data-source="props.postList"
    >
      <template #renderItem="{ item }">
        <a-list-item>
          <a-list-item-meta :description="item.content.slice(0, 66)">
            <template #title>
              <a href="https://www.antdv.com/">{{ item.title }}</a>
            </template>
            <template #avatar>
              <a-avatar :src="yunxi" />
            </template>
          </a-list-item-meta>
        </a-list-item>
      </template>
    </a-list>
  </div>
</template>

<script setup lang="ts">
import yunxi from "../assets/images/yunxi.png";

import { withDefaults, defineProps, toRefs } from "vue";

interface Props {
  postList: any[];
}

const props = withDefaults(defineProps<Props>(), {
  postList: () => [],
});
</script>

<style></style>
